<?php

class Sqlite3Db extends G_DB{
    public function escape($string) {
        return $this->_db_con->escapeString($string);
    }

    public function exec($sql) {
        return $this->_db_con->exec($sql);
    }

    public function fetch($rs) {
        return $rs->fetchArray();
    }

    public function free($rs) {
        return $rs->finalize();
    }

    public function getAffectedRows($rs) {
        return $this->_db_con->changes();
    }

    public function getInsertId($rs) {
        return $this->_db_con->lastInsertRowID();
    }

    public function query($sql) {
        return $this->_db_con->query($sql);
    }    
}
